package java8.lesson01;

public class TestAnonymousInterClass {
    // 在这个方法中构造一个匿名内部类
    private void show(Out out) {
        out.show();
    }


    public static void main(String[] args) {
        TestAnonymousInterClass test = new TestAnonymousInterClass();
        test.show(new Out() {
            @Override
            public void show() {
                System.out.println("匿名内部类-----");
            }
        });

        test.show(()->{
            System.out.println("就是要输出结果");
        });


    }
}